package com.ruix.app.mapper;

import com.ruix.app.cache.CacheFactory;
import com.ruix.app.model.ClassCourse;

import org.json.JSONObject;

/**
 * Created by hadexs on 2017/5/9.
 */

public class ClassCourseMapper implements ApiMapper<ClassCourse> {

    @Override
    public ClassCourse transform(JSONObject response) {
        //todo
        ClassCourse classCourse = null;
        if (response != null){
           JSONObject data = response.optJSONObject("data");
            if (data != null){
                classCourse = new ClassCourse().parse(data);

            }
        }
        return classCourse;
    }
}
